package com.lzh.dlykserver.mapper;

import com.lzh.dlykserver.commons.DataScope;
import com.lzh.dlykserver.entity.TActivity;
import com.lzh.dlykserver.query.ActivityQuery;
import com.lzh.dlykserver.query.BaseQuery;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author 墨墨
 * @description 针对表【t_activity(市场活动表)】的数据库操作Mapper
 * @createDate 2024-07-24 09:57:15
 * @Entity com.lzh.dlykserver.entity.TActivity
 */
public interface TActivityMapper {

    int deleteByPrimaryKey(Integer id);

    int insert(TActivity record);

    int insertSelective(TActivity record);

    TActivity selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(TActivity record);

    int updateByPrimaryKey(TActivity record);

    @DataScope(tableAlias = "ta", tableField = "owner_id")
    List<TActivity> selectUserByPage(ActivityQuery query);

    TActivity selectDetailByPrimaryKey(Integer id);

    int delByIds(@Param("idList") List<String> idList);

    List<TActivity> selectAllOnGoingActivity();

    Integer selectByCount();
}
